package org.dxy.domain.event.productionLine;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Value;
import org.dxy.domain.event.AggregateTypeEnum;
import org.dxy.domain.event.DomainEvent;

/**
 * @description: 产线配置更新事件
 */
@Value
@Builder
@AllArgsConstructor
public class ProductionLineReconfiguredEvent implements DomainEvent {
    /**
     * 产线 ID
     */
    Long lineId;

    /**
     * 原工艺路径 ID
     */
    Long originalProcessRouteId;

    /**
     * 新工艺路径 ID
     */
    Long newProcessRouteId;
    
    @Override
    public Long aggregateId() {
        return lineId;
    }
    
    @Override
    public String aggregateType() {
        return AggregateTypeEnum.PRODUCTION_LINE.getKey();
    }
    
    @Override
    public String eventType() {
        return ProductionLineEventTypeEnum.RECONFIGURED.getKey();
    }
} 